<template>
    <el-dialog :close-on-click-modal="false"  ref="dialogform" title="查看转入信息" :visible.sync="dialogVisible" width="60%" :before-close="handleClose">
        <el-table :data="tableData" style="width: 100%" border>
            <el-table-column type="index" width="50" label="序号">
            </el-table-column>
            <el-table-column prop="plantVarietyName" label="转入品种">
            </el-table-column>
            <el-table-column prop="fishType" label="转入类型">
                <template slot-scope="scope">
                    {{ scope.row.fishType == 'LIVE_FISH' ? '活鱼' : '' }}
                    {{ scope.row.fishType == 'DEAD_FISH' ? '直鱼' : '' }}
                    {{ scope.row.fishType == 'SECONDARY_FISH' ? '次鱼' : '' }}
                </template>
            </el-table-column>
            <el-table-column prop="specificationName" label="转入规格">
            </el-table-column>
            <el-table-column prop="num" label="转入数量(粒)">
            </el-table-column>
            <el-table-column prop="weight" label="转入重量(斤)">
            </el-table-column>
        </el-table>
        <span slot="footer" class="dialog-footer">
            <el-button @click="cancel">取 消</el-button>
        </span>
    </el-dialog>
</template>
<script>
export default {
    components: {},
    props: {
        addEditFlag: {
            type: String,
            default: () => {
                return 'add'
            }
        },
        tableData: {
            type: Array,
            default: () => {
                return []
            }
        },
        dialogVisible: {
            type: Boolean,
            default: () => {
                return false
            }
        }
    },
    data() {
        return {}
    },

    watch: {},

    mounted() {
        console.log(this.tableData)
    },
    methods: {
        //取消关闭
        cancel() {
            this.$emit("closeDialog")
        },
        handleClose(done) {
            this.$confirm('确认关闭？')
                .then(_ => { this.cancel() })
                .catch(_ => { });
        }
    }
};
</script>
<style lang="scss" scoped></style>
  